package records

import (
	"github.com/golib/mysql"
)

const RecordNameCmsCourseNode = "cms_course_node"

func init() {
	var r = &CmsCourseNode{}
	mysql.RegisterRecord(r.Name(), r)
}

type CmsCourseNode struct {
	NodeId      int    `json:"nodeId" form:"nodeId" column:"node_id" primary:"true" modify:"false"`
	CourseId    int    `modify:"true" json:"courseId" form:"courseId" column:"course_id"`
	NodeName    string `json:"nodeName" form:"nodeName" column:"node_name" modify:"true"`
	NodeType    int    `json:"nodeType" form:"nodeType" column:"node_type" modify:"true"`
	Level       int    `json:"level" form:"level" column:"level" modify:"true"`
	NeedStudy   int    `json:"needStudy" form:"needStudy" column:"need_study" modify:"true"`
	SuggestTime int    `column:"suggest_time" modify:"true" json:"suggestTime" form:"suggestTime"`
	ParentId    int    `json:"parentId" form:"parentId" column:"parent_id" modify:"true"`
	Order       int    `json:"order" form:"order" column:"order" modify:"true"`
	Url         string `json:"url" form:"url" column:"url" modify:"true"`
	CreateTime  string `json:"createTime" form:"createTime" column:"create_time" modify:"false"`
	UpdateTime  string `column:"update_time" modify:"false" json:"updateTime" form:"updateTime"`
	PositionX   int    `form:"positionX" column:"position_x" modify:"true" json:"positionX"`
	PositionY   int    `json:"positionY" form:"positionY" column:"position_y" modify:"true"`
}

func (r *CmsCourseNode) Name() string {
	return RecordNameCmsCourseNode
}
